{extend name="$_admin_base_layout" /}

{block name="style"}
<link href="__LIBS__/jquery-nestable/jquery.nestable.css" rel="stylesheet" type="text/css" />
{/block}

{block name="content"}
    <div class="row">
        <div class="col-md-12">
            <div class="block">
                <div class="block-header bg-gray-lighter">
                    <ul class="block-options">
                        <li>
                            <button type="button" data-toggle="block-option" data-action="refresh_toggle" data-action-mode="demo"><i class="si si-refresh"></i></button>
                        </li>
                        <li>
                            <button type="button" data-toggle="block-option" data-action="fullscreen_toggle"><i class="si si-size-fullscreen"></i></button>
                        </li>
                    </ul>
                    <h3 class="block-title">库存查询</h3>
                </div>
                <div class="block-content tab-content">
                    <div class="tab-pane active">
                        <div class="block-content">
                            <form class="form-horizontal form-builder row" name="form-builder" action="/admin.php/warehouse/stock/two_dimensional.html" method="get">
                                                                                
                                <div class="form-group col-md-3 " id="form_group_warehouseid">
                                    <label class="col-xs-12" for="warehouseid">仓库</label>
                                    <div class="col-sm-12">
                                        <select class="js-select2 form-control select2-hidden-accessible" id="warehouseid" name="warehouseid" data-allow-clear="true" data-placeholder="请选择一项" tabindex="-1" aria-hidden="true">
                                            <option value="">请选择</option>
                                            {volist name="warehousedata" id="vo"}
                                                <option value="{$vo.warehouseid}" {eq name='Think.get.warehouseid' value='$vo.warehouseid'} selected {/eq}>{$vo.warehousename}</option>
                                            {/volist}
                                        </select>
                                    </div>
                                </div>
                                                                                            
                                <div class="form-group col-md-3 " id="form_group_artno">
                                    <label class="col-xs-12" for="artno">款类</label>
                                    <div class="col-sm-12">
                                        <select class="js-select2 form-control select2-hidden-accessible" id="artno" name="artno" data-allow-clear="true" data-placeholder="请选择一项" tabindex="-1" aria-hidden="true">
                                            <option value="">请选择</option>
                                            {volist name="typedata" id="vo"}
                                                <option value="{$vo.classid}" {eq name='Think.get.artno' value='$vo.classid'} selected {/eq}>{$vo.artno}</option>
                                            {/volist}
                                        </select>
                                    </div>
                                </div>
                                <div class="form-group col-md-3 " id="form_group_artno">
                                    <label class="col-xs-12" for="artno">店铺</label>
                                    <div class="col-sm-12">
                                        <select class="js-select2 form-control select2-hidden-accessible" id="artno" name="shopid" data-allow-clear="true" data-placeholder="请选择一项" tabindex="-1" aria-hidden="true">
                                            <option value="">请选择</option>
                                            {volist name="shopdata" id="vo"}
                                                <option value="{$vo.id}" {eq name='Think.get.shopid' value='$vo.id'} selected {/eq}>{$vo.name}</option>
                                            {/volist}
                                        </select>
                                    </div>
                                </div>                                                    
                                
                                <div class="form-group col-md-4" id="form_group_btnGroup">
                                    <div class="col-xs-12">
										<br>
                                        <button type="submit" class="btn  btn-primary btn-rounded">确定搜索</button>                                    </div>
                                </div>
                            </form>
                        </div>
                    </div>
                </div>
                <div class="block-content tab-content">
                    <div class="row data-table-toolbar">
                        <div class="col-sm-12">
                            <div class="toolbar-btn-action">
                                <a title="列表查询" class="btn btn-info" target-form="ids" href="/admin.php/warehouse/stock/index.html" icon="fa fa-fw fa-slack"><i class="fa fa-fw fa-slack"></i> 列表查询</a>
                            </div>
                        </div>
                    </div>
                    <div class="table-responsive">
                        <table class="table table-builder table-hover table-bordered table-striped js-table-checkable "
                                style="table-layout:fixed;">
                            <thead>
                            <tr>
                                <th class="" style="text-align: center;vertical-align: middle;font-size: 17px;">颜色</th>
                                {volist name="sizedata" id="vo"}
                                    <th class="" style="text-align: center;vertical-align: middle;font-size: 17px;">{$vo.name}</th>
                                {/volist}
                            </tr>
                        </thead>
                        <tbody>
                            {volist name="colordata" id="vo"}
                                <tr>
                                    <td style="text-align: center;">{$vo.name}</td>
                                    {volist name="vo['stockdata']" id="v"}
                                        <td style="text-align: center;">{$v.num}</td>
                                    {/volist}
                                </tr>
                            {/volist}
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>
        </div>
    </div>
{/block}
<script src="/public/static/libs/select2/select2.full.min.js"></script>
{block name="script"}
{/block}
